package simple;

/**
 * @author rDiaconescu
 *
 */
public class Person {
	private String name;
	private int age;

	public Person(String name, int age) {
	    super();
	    this.name = name;
	    this.age = age;
    }
	
	protected void growOld() {
		age = age + 1;
	}
	
	protected void getMarried(String newName) {
		name = newName;
	}

	@Override
    public String toString() {
	    return "Person [name=" + name + ", age=" + age + "]";
    }
	
}
